CREATE TABLE [dbo].[TCCANJ_CL02]
(
[CO_EMPR] [dbo].[TD_VC_002] NOT NULL,
[CO_UNID_CONC] [dbo].[TD_VC_003] NOT NULL,
[CO_CLIE] [dbo].[TD_VC_020] NOT NULL,
[NU_CANJ] [dbo].[TD_VC_008] NOT NULL,
[FE_CANJ] [dbo].[TD_DT_001] NOT NULL,
[CO_MONE] [dbo].[TD_VC_003] NOT NULL,
[FA_TIPO_CAMB] [dbo].[TD_NU_015_006] NOT NULL CONSTRAINT [DF__TCCANJ_CL__FA_TI__5165187F] DEFAULT ((1.000)),
[CO_TIPO_OPER] [dbo].[TD_VC_003] NOT NULL,
[FE_INIC_VMTO] [dbo].[TD_DT_001] NULL,
[NU_LETR_GENE] [dbo].[TD_IN_001] NULL CONSTRAINT [DF__TCCANJ_CL__NU_LE__52593CB8] DEFAULT ((0)),
[ST_PLAZ_VMTO] [dbo].[TD_VC_001] NULL,
[NU_DIAS_PLAZ] [dbo].[TD_IN_001] NULL CONSTRAINT [DF__TCCANJ_CL__NU_DI__534D60F1] DEFAULT ((0)),
[NU_DIFE_DIAS] [dbo].[TD_IN_001] NULL CONSTRAINT [DF__TCCANJ_CL__NU_DI__5441852A] DEFAULT ((0)),
[ST_FECH_VMTO] [dbo].[TD_VC_001] NULL,
[NU_DIAS_MESE] [dbo].[TD_IN_001] NULL CONSTRAINT [DF__TCCANJ_CL__NU_DI__5535A963] DEFAULT ((0)),
[ST_DIAS_FMES] [dbo].[TD_VC_001] NULL,
[DE_OBSE] [dbo].[TD_VC_100] NULL,
[ST_CONT] [dbo].[TD_VC_001_INTE] NOT NULL CONSTRAINT [DF__TCCANJ_CL__ST_CO__5629CD9C] DEFAULT ('N'),
[NU_PROC] [dbo].[TD_IN_001] NULL CONSTRAINT [DF__TCCANJ_CL__NU_PR__5812160E] DEFAULT ((0)),
[TI_SITU] [dbo].[TD_VC_003] NOT NULL,
[ST_CANJ] [dbo].[TD_VC_001_SINO] NULL CONSTRAINT [DF__TCCANJ_CL__ST_CA__59063A47] DEFAULT ('N'),
[PC_INTR_MENS] [dbo].[TD_NU_009_004] NULL CONSTRAINT [DF__TCCANJ_CL__PC_IN__5AEE82B9] DEFAULT ((0)),
[IM_GAST_BANC] [dbo].[TD_NU_016_004] NULL CONSTRAINT [DF__TCCANJ_CL__IM_GA__5BE2A6F2] DEFAULT ((0)),
[NU_ASTO] [dbo].[TD_VC_010] NULL,
[ST_ACEP] [dbo].[TD_VC_001] NULL,
[CO_USUA_CREA] [dbo].[TD_VC_008_USUA] NOT NULL CONSTRAINT [DF__TCCANJ_CL__CO_US__5CD6CB2B] DEFAULT (suser_sname()),
[FE_USUA_CREA] [dbo].[TD_DT_001_SIST] NOT NULL CONSTRAINT [DF__TCCANJ_CL__FE_US__5DCAEF64] DEFAULT (getdate()),
[CO_USUA_MODI] [dbo].[TD_VC_008_USUA] NOT NULL CONSTRAINT [DF__TCCANJ_CL__CO_US__5EBF139D] DEFAULT (suser_sname()),
[FE_USUA_MODI] [dbo].[TD_DT_001_SIST] NOT NULL CONSTRAINT [DF__TCCANJ_CL__FE_US__5FB337D6] DEFAULT (getdate())
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[TCCANJ_CL02] WITH NOCHECK ADD CONSTRAINT [CK__TCCANJ_CL__ST_CA__59FA5E80] CHECK NOT FOR REPLICATION (([ST_CANJ]='N' OR [ST_CANJ]='S'))
GO
ALTER TABLE [dbo].[TCCANJ_CL02] WITH NOCHECK ADD CONSTRAINT [CK__TCCANJ_CL__ST_CO__571DF1D5] CHECK NOT FOR REPLICATION (([ST_CONT]='P' OR [ST_CONT]='N'))
GO
ALTER TABLE [dbo].[TCCANJ_CL02] ADD CONSTRAINT [PK__TCCANJ_C__2F266C7572A6DC10] PRIMARY KEY CLUSTERED  ([CO_EMPR], [CO_UNID_CONC], [CO_CLIE], [NU_CANJ], [FE_CANJ]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[TCCANJ_CL02] ADD CONSTRAINT [FK__TCCANJ_CL__CO_EM__762D5431] FOREIGN KEY ([CO_EMPR]) REFERENCES [dbo].[TMPARA_TESO] ([CO_EMPR])
GO
